#include <gtest/gtest.h>
#include <string>
#include <memory>
#include <vector>

// 示例测试套件
TEST(ExampleTest, BasicAssertions) {
    // 基本断言
    EXPECT_STRNE("hello", "world");
    EXPECT_EQ(7 * 6, 42);
}

// 智能指针测试
TEST(ExampleTest, SmartPointer) {
    auto ptr = std::make_unique<std::string>("test");
    EXPECT_EQ(*ptr, "test");
    EXPECT_TRUE(ptr != nullptr);
}

// 异常测试
TEST(ExampleTest, ExceptionTest) {
    EXPECT_THROW({
        std::vector<int> vec;
        [[maybe_unused]] int val = vec.at(5);  // 存储返回值
    }, std::out_of_range);
} 